package com.acme.task2;

public class GCTest
{
	byte array[] = new byte[1024];
	private static final int N = 10000000;

	public static void main(String[] args)
	{
		int numberOfIterations = N;
		// GC was not called when numberOfIterations = 1000, 100000
		// because there was enough free memory in heap at the time
		
		Foo[] foo = new Foo[N];
		for (int i = 0; i < numberOfIterations; i++)
		{
			foo[i] = new Foo(i);
		}
	}
}